package smallDemend;

import java.util.Scanner;

//键盘录入一个正整数，判断该整数是否为一个质数
public class Prime {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        System.out.println("请输入正整数：");
        int number = sc.nextInt();
        boolean b = true;
        for (int i = 2; i < number; i++) {
            if (number % i == 0) {
                b = false;
                break;
            }
        }
        System.out.println(b);

    }
}
